/*
 * Copyright (c) zhg2yqq.com Corp.
 * All Rights Reserved.
 */
package com.zhg2yqq.wheels.mvc;

import java.util.List;

import org.springframework.boot.context.properties.ConfigurationProperties;

/**
 * @author zhg2yqq, 2023年3月26日
 * @version zhg2yqq v1.0
 */
@ConfigurationProperties(prefix = "mybatis.tenant")
public class MybatisTenantProperties {
    /**
     * 是否启用多租户
     */
    private boolean enable = false;
    /**
     * 多租户标识数据库字段
     */
    private String tenantColumn = "tenant_id";
    /**
     * 默认租户id值
     */
    private String tenantId = "0";
    /**
     * 允许多租户区分的表名
     */
    private List<String> tenantTableNames;

    public MybatisTenantProperties() {
    }

    public boolean isEnable() {
        return enable;
    }

    public void setEnable(boolean enable) {
        this.enable = enable;
    }

    public String getTenantColumn() {
        return tenantColumn;
    }

    public void setTenantColumn(String tenantColumn) {
        this.tenantColumn = tenantColumn;
    }

    public String getTenantId() {
        return tenantId;
    }

    public void setTenantId(String tenantId) {
        this.tenantId = tenantId;
    }

    public List<String> getTenantTableNames() {
        return tenantTableNames;
    }

    public void setTenantTableNames(List<String> tenantTableNames) {
        this.tenantTableNames = tenantTableNames;
    }
}
